cmake_minimum_required(VERSION 3.16)
project(List)

set(var a B C d)
message("var = ${var}")

list(TRANSFORM var APPEND e)
message("APPEND -- ${var}")

list(TRANSFORM var PREPEND F OUTPUT_VARIABLE outvar)
message("PREPEND -- ${var}")
message("outvar = ${outvar}")

list(TRANSFORM var TOUPPER)
message("TOUPPER -- ${var}")

list(TRANSFORM var TOLOWER)
message("TOLOWER -- ${var}")

set(var a b)
list(APPEND var "   c" "d   " "   e   ")
message("var = ${var}")

list(TRANSFORM var STRIP)
message("STRIP -- ${var}")

set(var a $<BOOL:FALSE> $<BOOL:YES> b c)
message("var = ${var}")

list(TRANSFORM var GENEX_STRIP)
message("GENEX_STRIP -- ${var}")

set(var a b cc dd e f)
message("var = ${var}")

list(TRANSFORM var REPLACE "[a-z][a-z]" xx)
message("REPLACE -- ${var}")

list(TRANSFORM var TOUPPER AT 0 1 3 4)
message("TOUPPER AT -- ${var}")

list(TRANSFORM var TOLOWER FOR 1 3)
message("TOLOWER FOR -- ${var}")

list(TRANSFORM var TOUPPER REGEX "[a-z][a-z]")
message("TOUPPER REGEX -- ${var}")
